From: Timo Tijhof Date: Sat, 21 Sep 2019 01:31:04 +0000 (+0100) Subject: localisation: Remove PHP5-specific perf optimisation X-Git-Tag: 1.34.0-rc.0~126^2 X-Git-Url: https://git.cyclocoop.org/%27.WWW_URL.%27admin//%22%24path/%7B%24disabledImages%5B%24type%5D%7D/%22?a=commitdiff_plain;h=7d82ce8bfdda964197a46e5da863c2c59eac8a0c;p=lhc%2Fweb%2Fwiklou.git localisation: Remove PHP5-specific perf optimisation The `apc.cache_by_default` setting is a PHP5-era setting relating to the part of php5-apc now known as opcache (as opposed to the part now known as apcu). This setting doesn't exist in PHP 7, and trying to set it doesn't do anything useful. Bug: T206986 Change-Id: I46a91897b2b33b5ce6505beb74d404982cb0641c --- diff --git a/includes/cache/localisation/LocalisationCache.php b/includes/cache/localisation/LocalisationCache.php index 26468452b4..c6d6b8fa5b 100644 --- a/includes/cache/localisation/LocalisationCache.php +++ b/includes/cache/localisation/LocalisationCache.php @@ -519,17 +519,8 @@ class LocalisationCache { * @return array */ protected function readPHPFile( $_fileName, $_fileType ) { - // Disable APC caching - Wikimedia\suppressWarnings(); - $_apcEnabled = ini_set( 'apc.cache_by_default', '0' ); - Wikimedia\restoreWarnings(); - include $_fileName; - Wikimedia\suppressWarnings(); - ini_set( 'apc.cache_by_default', $_apcEnabled ); - Wikimedia\restoreWarnings(); - $data = []; if ( $_fileType == 'core' || $_fileType == 'extension' ) { foreach ( self::$allKeys as $key ) {